package com.cskt.securityproject.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @description 自定义web
 * @date 2023/12/13 10:26
 * @auth mo
 */
@Configuration
public class WebConfiguration implements WebMvcConfigurer {

    @Override
    public void addViewControllers(ViewControllerRegistry registry) {
        registry.addViewController("/toLoginPage")
                .setViewName("login");
        registry.addViewController("/")
                .setViewName("index");
        registry.addViewController("/user/add")
                .setViewName("user_add");
    }
}
